package com.gray.blog.arg.sys;

import com.gray.blog.common.arg.BaseArg;
import io.swagger.annotations.ApiModelProperty;
import javax.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import org.apache.commons.lang3.StringUtils;

/**
 * Created  By zhoux 2020/04/22
 **/
@Data
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
public class UpdateGameArg extends BaseArg {

    @ApiModelProperty(value = "游戏名")
    @NotNull
    private String name;

    @ApiModelProperty(value = "简介")
    @NotNull
    private String introduction;

    @ApiModelProperty(value = "评测")
    @NotNull
    private String evaluation;

    @ApiModelProperty(value = "封面图")
    @NotNull
    private String cover;

    @ApiModelProperty(value = "是否示于主页")
    @NotNull
    private Integer showInFront;

    public boolean isWrongParam() {
        return StringUtils.isBlank(getId());
    }

}
